package com.learn.spring.conditional;

import org.springframework.beans.BeansException;
import org.springframework.beans.factory.config.BeanPostProcessor;
import org.springframework.stereotype.Component;

/**
 * @author wangxing
 * @version 2020/6/12 14:04 Administrator
 */
@Component
public class TempProcessor implements BeanPostProcessor {
    @Override
    public Object postProcessBeforeInitialization(Object bean, String beanName) throws BeansException {
        System.out.println("TempProcessor...postProcessBeforeInitialization:" + beanName);
        return bean;
    }

    @Override
    public Object postProcessAfterInitialization(Object bean, String beanName) throws BeansException {
        System.out.println("TempProcessor...postProcessAfterInitialization:" + beanName);
        return bean;
    }
}
